<?php

function request_to_database($sql_str) {
    $link = mysql_connect('localhost', 'root', 'the1soop');
    mysql_select_db('lectures');

    $fetched_result = mysql_fetch_array(mysql_query($sql_str));

    mysql_close($link);
    return ($fetched_result);
}